
export const formatPrice = (fen) => {
    if (fen === null || fen === undefined || isNaN(fen)) {
        return '¥0.00';
    }
    
    const yuan = fen / 100;
    return `¥${yuan.toFixed(2)}`;
};

export const formatPriceWithoutSymbol = (fen) => {
    if (fen === null || fen === undefined || isNaN(fen)) {
        return '0.00';
    }
    
    const yuan = fen / 100;
    return yuan.toFixed(2);
};
